import axios from 'axios'

axios.defaults.baseURL = 'http://localhost:7002'

axios.interceptors.request.use(req => {
    req.headers.authorization = localStorage.getItem('token')
    return req
})

axios.interceptors.response.use(res => {
    return res.data
})

export default axios